package com.scjp_Java6.AccesingStaticMethodsAndVariables;



class Animal{
	static void doStuff(){
		System.out.println("a ");
	}
}

public class Dog extends Animal{
	static void doStuff(){		//it's a redefinition, not an overriden
		
		System.out.println("d ");
	}
	
	public static void main(String[] args) {
		Animal[] a={new Animal(),new Dog(),new Animal()};
		for(int x=0;x<a.length;x++) {
			//			a[x].doStuff();		//invoke the static method
			Animal.doStuff();
		}	
	}

}
